How to Embed a YouTube Video

This tutorial explains how to embed a YouTube video into a webpage.

Step-by-Step Instructions

Step 1: Open the video on YouTube

I opened the video on YouTube.

YouTube video page

Step 2: Click Share

I clicked the Share button under the video.

Share button

Step 3: Click Embed

I selected the Embed option.

Embed option

Step 4: Copy the embed code

I copied the iframe code.

Embed code

Step 5: Paste the code into HTML

I pasted the iframe into my index.html file.

Iframe in HTML

Step 6: Add styling to the external CSS file

I added styling to my external CSS file.

External CSS file

Step 7: Test the video

I refreshed the page to make sure the video worked.

Testing Video

*Example Video*